﻿@using System.Net.Http
@model System.Web.Http.Description.IApiExplorer
<div id="body" style="overflow: visible">
    <section class="featured">
        <div class="content-wrapper">
            <hgroup class="title">
                <h1>
                    Schedule Web API</h1>
            </hgroup>
        </div>
    </section>
    <section class="content-wrapper main-content clear-fix">
        <ul>
            @foreach (var api in Model.ApiDescriptions.OrderBy(x => x.RelativePath))
            {
                if (!api.RelativePath.Contains("?"))
                { 
                    <li>
                        <h5>@api.HttpMethod: @api.RelativePath.ToLower()</h5>
                            <p>@api.Documentation</p>
                            @if (api.ParameterDescriptions.Count > 0)
                            {
                                <p><b>Parameters</b>
                                    <ul>
                                        @foreach (var parameter in api.ParameterDescriptions)
                                        {
                                            <li>@parameter.Name: @parameter.Documentation (@parameter.Source)</li>
                                        }
                                    </ul>
                                </p>
                            }
                    </li><br />
                }
            }
        </ul>
    </section>
</div>
